<!DOCTYPE html>
<html>

	<head>
		<meta content="text/html; charset=UTF-8" http-equiv="Content-Type" />
		<meta content="width=device-width,minimum-scale=1.0,maximum-scale=1.0,user-scalable=no" name="viewport" />
		<meta content="telephone=no" name="format-detection" />
		<meta content="address=no" name="format-detection" />
		<meta name="apple-mobile-web-app-capable" content="no" />
		<link rel="apple-touch-icon-precomposed" href="http://img0.zz91.com/zz91/images/logo.png" />
		<link rel="apple-touch-icon-precomposed" sizes="114x114" href="apple-touch-icon-precomposed" />
		<meta name="apple-touch-fullscreen" content="YES">
		<meta name="apple-mobile-web-app-capable" content="yes">
		<meta name="apple-mobile-web-app-status-bar-style" content="black">
		<link rel="shortcut icon" href="http://img0.zz91.com/front/favicon.ico" />
		<title></title>
		<link rel="stylesheet" type="text/css" href="http://b.zz91.com/layui/css/layui.css" />
		<script type="text/javascript" src="http://b.zz91.com/layui/layui.js"></script>
		<style>
			.mainbox {
				margin: 10px;
			}
		</style>
	</head>

	<body>
		<div class="mainbox">
			<form class="layui-form" action="storage_save.html" method="post">
				<!--<div class="layui-form-item">
				    <label class="layui-form-label">产品编号</label>
				    <div class="layui-input-block">
				      	<input type="text" name="id" lay-verify="title" autocomplete="off" placeholder="请输入产品编号" class="layui-input">
				    </div>
			  	</div>-->
				
				<div class="layui-form-item">
					<label class="layui-form-label"><span style="color: red;">*</span>产品名称</label>
					<div class="layui-input-block">
						<select name="products_selfid">
					<option value="">请选择...</option>
					{% for list in product_list%}
					<option value="{{list.id}}">{{list.name}}</option>
					{%endfor%}
					</select>
					</div>
				</div>
				
				<div class="layui-form-item">
					<label class="layui-form-label"><span style="color: red;">*</span>供货商</label>
					<div class="layui-input-block">
						<select name="suppliers_selfid">
				<option value="">请选择...</option>
				{% for list in supplier_list%}
				<option value="{{list.id}}">{{list.name}}</option>
				{%endfor%}</select>
					</div>
				</div>
				
				<div class="layui-form-item">
					<label class="layui-form-label"><span style="color: red;">*</span>单号</label>
					<div class="layui-input-block">
						<input type="text" name="code" lay-verify="required" autocomplete="off" placeholder="请输入单号" class="layui-input">
					</div>
				</div>

				<div class="layui-form-item">
					<label class="layui-form-label"><span style="color: red;">*</span>价格</label>
					<div class="layui-input-block">
						<input type="text" name="price" lay-verify="required" autocomplete="off" placeholder="请输入价格" class="layui-input">
					</div>
				</div>

				<div class="layui-form-item">
					<label class="layui-form-label"><span style="color: red;">*</span>毛重</label>
					<div class="layui-input-block">
						<input type="text" name="gw" lay-verify="required|number" placeholder="请输入毛重" autocomplete="off" class="layui-input">
					</div>
				</div>

				<div class="layui-form-item">
					<label class="layui-form-label"><span style="color: red;">*</span>净重</label>
					<div class="layui-input-block">
						<input type="text" name="nw" lay-verify="required|number" placeholder="请输入净重" autocomplete="off" class="layui-input">
					</div>
				</div>

				<div class="layui-form-item">
					<label class="layui-form-label"><span style="color: red;">*</span>皮重</label>
					<div class="layui-input-block">
						<input type="text" name="tare" lay-verify="required|number" placeholder="请输入皮重" autocomplete="off" class="layui-input">
					</div>
				</div>

				<div class="layui-form-item">
					<label class="layui-form-label"><span style="color: red;">*</span>总价</label>
					<div class="layui-input-inline">
						<input type="tel" name="total" lay-verify="required|number" placeholder="请输入总价" autocomplete="off" class="layui-input">
					</div>
				</div>

				<div class="layui-form-item layui-form-text">
					<label class="layui-form-label"><span style="color: red;">*</span>订单状态</label>
					 <div class="layui-input-block">
					<select name="status" style="display: None;">
						<option value="">请选择...</option>
						<option value="0">过磅中</option>
						<option value="1">过磅完成</option>
						<option value="2">定价完成</option>
						<option value="3">完成皮重</option>
						<option value="4">结算完成</option>
						<option value="99">作废</option>
					</select>
					</div>
				</div>

				<div class="layui-form-item layui-form-text">
					<label class="layui-form-label"><span style="color: red;">*</span>经手人</label>
					<div class="layui-input-block">
						<select name="price_users_selfid">
				<option value="">请选择...</option>
				{% for list in user_list%}
				<option value="{{list.id}}">{{list.contact}}</option>
				{%endfor%}</select>
					</div>
				</div>

				<div class="layui-form-item layui-form-text">
					<label class="layui-form-label"><span style="color: red;">*</span>定价时间</label>
					<div class="layui-input-inline">
						<input type="text" name="price_time" id="date" lay-verify="date" placeholder="yyyy-MM-dd" autocomplete="off" class="layui-input">
					</div>
				</div>

				<div class="layui-form-item layui-form-text">
					<label class="layui-form-label"><span style="color: red;">*</span>是否支付</label>
					<div class="layui-input-block">
					<select name="ispay" style="display: None;">
						<option value="">请选择...</option>
						<option value="0">未支付</option>
						<option value="1">已支付</option>
						<option value="2">积分结算</option>
					</select>
					</div>
				</div>

				<div class="layui-form-item layui-form-text">
					<label class="layui-form-label"><span style="color: red;">*</span>积分是否提现</label>
					<div class="layui-input-block">
					<select name="scorecheck" style="display: None;">
						<option value="">请选择...</option>
						<option value="0">未提现</option>
						<option value="1">已提现</option>
					</select>
					</div>
				</div>

				<div class="layui-form-item layui-form-text">
					<label class="layui-form-label"><span style="color: red;">*</span>支付时间</label>
					<div class="layui-input-inline">
						<input type="text" name="pay_time" id="date" lay-verify="date" placeholder="yyyy-MM-dd" autocomplete="off" class="layui-input">
					</div>
				</div>

				<div class="layui-form-item layui-form-text">
					<label class="layui-form-label"><span style="color: red;">*</span>支付人员</label>
					<div class="layui-input-block">
						<select name="pay_users_selfid">
				<option value="">请选择...</option>
				{% for list in user_list%}
				<option value="{{list.id}}">{{list.contact}}</option>
				{%endfor%}</select>
					</div>
				</div>

				<div class="layui-form-item layui-col">
					<div class="layui-input-block">
						<button type="reset" class="layui-btn layui-btn-primary layui-col-xs2">清除</button>
						<button class="layui-btn layui-btn-normal layui-col-xs2" lay-submit="" lay-filter="demo1">保存</button>
					</div>
				</div>
				<input type="hidden" name="company_id" value={{company_id}} />
				<input type="hidden" name="group_id" value={{group_id}} />
				<input type="hidden" name="company_id" value={{company_id}}/>
				<input type="hidden" name="products_selfid" value={{products_selfid}} />
			</form>
		</div>

	</body>
	<script>
		layui.use(['form', 'layedit', 'laydate'], function() {
			var form = layui.form,
				layer = layui.layer,
				layedit = layui.layedit,
				laydate = layui.laydate;

			//日期
			laydate.render({
				elem: '#date'
			});
			laydate.render({
				elem: '#date1'
			});

			//自定义验证规则
			form.verify({
				pass: [/(.+){6,12}$/, '密码必须6到12位'],
				content: function(value) {
					layedit.sync(editIndex);
				}
			});

		});
	</script>

</html>